﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Web.PageUI.Page_Product
{
    public class List : BaseList
    {
        public List()
        {
            //this.Load += new EventHandler(List_Load);
            List<dynamic> channellist = new Evan.DataBase.DbOperat("Channel").GetList_1(0, "ParentId=@0 and States=1", "Id asc", ClassId);
            if (channellist.Count == 0)
            {
                PageLists = curBLL.GetPage_2(curPageSize, curPage, string.Format(" ClassId={0} and States=1 ", ClassId), curChannelOrderBy);
            }
            else
            {
                string str = ClassId + ",";
                foreach (var item in channellist)
                {
                    str += item.Id + ",";
                }
                PageLists = curBLL.GetPage_2(curPageSize, curPage, string.Format(" ClassId in ({0}) and States=1 ", str.Trim(',')), curChannelOrderBy);
            }
        }

        private void List_Load(object sender, EventArgs e)
        {

        }


       
    }
}
